import java.util.ArrayList;
import java.util.Date;
import java.util.List;


public class ChatData {
	
	private List<Message> messages = new ArrayList<Message> ();
	private Message currentMessage = new Message();
	
	public void addMessage(){
		getCurrentMessage().setDate(new Date());
		getMessages().add(getCurrentMessage());
		setCurrentMessage(new Message());
	}

	public void setCurrentMessage(Message currentMessage) {
		this.currentMessage = currentMessage;
	}

	public Message getCurrentMessage() {
		return currentMessage;
	}

	public void setMessages(List<Message> messages) {
		this.messages = messages;
	}

	public List<Message> getMessages() {
		return messages;
	}



}
